﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;

namespace BankCreditPortfolio.Areas.Admin.Models
{
    public class TariffModel
    {
        [Display(Name = "Title")]
        public string Title { get; set; }

        [Display(Name = "Description")]
        public string Description { get; set; }

        [Display(Name = "Fine (the amount of penalty for arrears of payment)")]
        public float Fine { get; set; }

        [Display(Name = "Currency")]
        public string Currency { get; set; }

        [Display(Name = "Percent")]
        public virtual int CreditPercent { get; set; }

        [Display(Name = "Require Guarantor")]
        public bool RequireGuarantor { get; set; }

        [Display(Name = "First Payment")]
        public decimal FirstPayment { get; set; }

        [Display(Name = "Other Payments")]
        public decimal OtherPayments { get; set; }

        [Display(Name = "Minimum Sum")]
        public decimal Min { get; set; }

        [Display(Name = "Maximum Sum")]
        public decimal Max { get; set; }

        [Display(Name = "Percent")]
        public int Percent { get; set; }

        [Display(Name = "Term")]
        public DateTime Time { get; set; }

        [Display(Name = "Years")]
        public virtual int Years { get { return this.Time.Year - 2000; } }

        [Display(Name = "Months")]
        public virtual int Months { get { return this.Time.Month - 1; } }

        [Display(Name = "Pre-term Repay Fine")]
        public virtual int EarlyRepaimentFine { get; set; }

        [Display(Name = "Is used")]
        public virtual bool Used { get; set; }
    }
}